/*
 * Galaxium Messenger
 * Copyright (C) 2007 Ben Motmans <ben.motmans@gmail.com>
 * 
 * License: GNU General Public License (GPL)
 *
 * This program is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License as published by the Free
 * Software Foundation; either version 2 of the License, or (at your option)
 * any later version.
 *
 * This program is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
 * or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 * for more details.
 *
 * You should have received a copy of the GNU General Public License along
 * with this program; if not, write to the Free Software Foundation, Inc.,
 * 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */

using System;

using Galaxium.Gui;

namespace Galaxium.AdiumThemes
{
	public class AdiumSound: AbstractSound
	{
		public AdiumSound(string sound, string filename)
			: base(GetSound(sound), filename)
		{
		}
		
		private static Sound GetSound(string soundType)
		{
			if (soundType == "Connecting")
				return Sound.Connecting;
			if (soundType == "Connected")
				return Sound.Connected;
			if (soundType == "Disconnected")
				return Sound.Disconnected;
			if (soundType == "Error")
				return Sound.Error;
				
			if (soundType == "Contact Signed On")
				return Sound.ContactSignOn;
			if (soundType == "Contact Signed Off")
				return Sound.ContactSignOff;
			
			if (soundType == "Message Received")
				return Sound.MessageReceived;
			if (soundType == "Message Received (New)")
				return Sound.MessageReceivedNew;
			if (soundType == "Message Received (Stranger)")
				return Sound.MessageReceivedStranger;
			if (soundType == "Message Sent")
				return Sound.MessageSent;
				
			if (soundType == "File Transfer Began")
				return Sound.FileTransferBegan;
			if ((soundType == "File Transfer Canceled Remotely") || (soundType == "File Transfer Canceled"))
				return Sound.FileTransferCancel;
			if (soundType == "File Transfer Complete")
				return Sound.FileTransferComplete;
			if ((soundType == "File Transfer Request") || (soundType == "File Request"))
				return Sound.FileTransferRequest;
			if (soundType == "File Transfer Failed")
				return Sound.FileTransferFailed;
			
			if (soundType == "New Mail Received")
				return Sound.NewMailReceived;
			
			return Sound.None;
		}
	}
}
